<?php

namespace app\common\model;
/**
 * [CompanyHuyuan  寺院还愿表]
 * @author [C。]
 * @return html
 */
class CompanyManualOrder extends Base
{
    protected $name = 'company_manual_order';
    /**
     * 根据搜索条件获取佛事预约列表信息
     */
    public function getlist($map,$from = 0, $size = 5,$field = '*')
    {
        $order = ['id' => 'desc'];
        $result =  $this->field($field)
            ->where($map)
            ->order($order)
            ->limit($from, $size)
            ->select();

        return $result;
    }
    /**
     * 根据搜索条件获取佛事预约列表信息
     */
    public function getCount($map)
    {

        $result =  $this->where($map)->count();

        return $result;
    }
}